package lmscript.postscript;

import java.io.IOException;

import lmscript.postscript.syntax.PSObject;
import lmscript.postscript.syntax.stack.ClippingPathStack;
import lmscript.postscript.syntax.stack.DictionaryStack;
import lmscript.postscript.syntax.stack.ExecutionStack;
import lmscript.postscript.syntax.stack.GraphicsStateStack;
import lmscript.postscript.syntax.stack.OperandStack;

public class Interpreter {

	private VirtualCanvas canvas;

	private OperandStack opStack;
	private ExecutionStack exeStack;
	private DictionaryStack dictStack;
	private ClippingPathStack cpStack;
	private GraphicsStateStack gsStack;

	private Scanner scanner;

	public Interpreter() {
	}

	public boolean run() throws IOException {
		PSObject obj = scanner.next();
		boolean pop = obj.execute(opStack, true);
		
		return false;
	}

	public OperandStack getOperandStack() {
		return this.opStack;
	}

	public ExecutionStack getExecutionStack() {
		return this.exeStack;
	}

	public DictionaryStack getDictStack() {
		return this.dictStack;
	}

	public ClippingPathStack getClippingPathStack() {
		return this.cpStack;
	}

	public GraphicsStateStack getGraphicsStateStack() {
		return this.gsStack;
	}
}
